import { type } from "../action"

const initState = {

}

export default (state = initState, action: { type: any; testNum: number; username: any }) => {
    switch (action.type) {
        case type.SEND_TYPE:

            return {
                ...state,
                testNum: action.testNum + 1
            }
        case type.USER_NAME: {
            return {
                ...state,
                username: action.username,
            }
        }
        default:
            return state
    }
}
